package com.haopt.annotation.importlearn;

import com.haopt.test.EnableUser;
import com.haopt.test.TUser;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Import;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author haopt
 * @version 1.0
 * @ClassName ImportConfig
 * @Description 测试类
 * @date 2021/5/12 10:52
 */


@Import(MyImportBeanDefinitionRegistrar.class)
@EnableUser
@RestController
public class ImportConfig {

    @Autowired
    private TUser user;
    @Autowired
    private com.haopt.annotation.importlearn.Import anImport;


    @GetMapping("/import")
    public void importTset(){
        System.out.println(user);
        System.out.println(anImport);
    }

}
